import request from '@/utils/request'

// 获取分页数据 
export function page(form, pageSize, currentPage) {
  return request.post('/order/page', {
    param: form,
    pageSize: pageSize,
    pageNo: currentPage
  })
}

// 根据接车单id和工单类型查询是否有工单，有返回工单信息，没有返回接车单信息
export function findOrderByPickCarId(data) {
  return request.post('/order/findOrderByPickCarId', data)
}

//退款回调
export function refundCallBack(data) {
  return request.post('/order/refundCallBack', data)
}

//付款回调
export function payCallBack(data) {
  return request.post('/order/payCallBack', data)
}

//退款流程
export function refundProcess(refundAuditStatus, data) {
  const auditRecordRefundSaveDomain = {
    ...data
  }
  return request.post(`/order/refundProcess?refundAuditStatus=${refundAuditStatus}`, auditRecordRefundSaveDomain)
}


//退款审核记录
export function refundProcessHistory(id, data) {
  return request.get(`/order/refundProcess/${id}`, data)
}